var fs = require("fs");
var cheerio = require('cheerio');


fs.readFile('../sd.html', function (err, data) {
    if (err) {
        throw err;
    } else {
        var html = data.toString();
        $ = cheerio.load(html);
        // var a = $('div .or_search_list');
        // for (var i = 0, len = a.length; i < len; i++) {
        //     //console.log($(a[i]).find("a").text());
        // }

        var a = $("div.or_search_list >> div.or_search_row_content").toArray();

        for (let obj of a) {
            var companyName = $(obj).children('a').text();
            console.log(companyName);

            var spans_div2 = $(obj).children("div.or_search_row_company").text();
            console.log(spans_div2);

            var spans_div3 = $(obj).children("div.or_search_row_history").text();
            console.log(spans_div3);
        }
    }
});